package com.cedar.util.listener; 

import javax.servlet.ServletContextEvent;  
import javax.servlet.ServletContextListener;  
import org.slf4j.Logger;  
import org.slf4j.LoggerFactory;  
import ch.qos.logback.classic.LoggerContext;  
import ch.qos.logback.classic.joran.JoranConfigurator;  
import ch.qos.logback.core.joran.spi.JoranException;  


public class LogbackConfigListener implements ServletContextListener {  

	@Override
	public void contextInitialized(ServletContextEvent event) {
		 LogbackWebConfigurer.initLogging(event.getServletContext());
		
	}
	
	@Override
	public void contextDestroyed(ServletContextEvent event) {
		LogbackWebConfigurer.shutdownLogging(event.getServletContext());
	}

}
 